﻿import lite.mobile.lib.utils.Delegate;
import lite.mobile.lib.components.*;
import lite.mobile.lib.WeeUIMain;

/**
 * @author alibber
 */
class Main {
	public function Main() {
		
		WeeUIMain.getInstance().initRoot();
		/*
		var btn : UTextButton = new UTextButton("btn" ,0);
		btn.dependOnUI(WeeUIMain.getInstance().getStageUI());
		btn.setText("1234567三四五六七八九十1232454jguhg");
		trace("sezhi: " + btn.getTextField());
		btn.toEnabled();
		*/
		/*
		var btn : UImageButton = new UImageButton("btn" ,0);
		btn.dependOnUI(WeeUIMain.getInstance().getStageUI());
		btn.setLike("LikeIamge");
		
		*/
		
		var btn : UStateButton = new UStateButton("btn" ,0);
		btn.dependOnUI(WeeUIMain.getInstance().getStageUI());
		btn.setLike("LikeIamge");
		btn.toSelect();
		
		btn.onPress = Delegate.create(this, onPress2) ;
	}

	private function onPress2(target:MovieClip):Void {
		trace("tttttttttttttt");
		trace(target);
	}
}
